package md.lanjing.com.module_wallet.ui.adapter;

import android.support.annotation.Nullable;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.lxh.baselibray.util.TimeUtils;

import java.util.List;

import md.lanjing.com.module_wallet.R;
import md.lanjing.com.module_wallet.bean.TransferRecordResponce;


public class TranferRecordAdapter extends BaseQuickAdapter<TransferRecordResponce.DataBean,BaseViewHolder> {
    public TranferRecordAdapter(int layoutResId, @Nullable List<TransferRecordResponce.DataBean> data) {
        super(layoutResId, data);
    }

    @Override
    protected void convert(BaseViewHolder helper, TransferRecordResponce.DataBean item) {
        helper.setText(R.id.tv_tranfer_id,"对方帐户:"+item.getOther())
                .setText(R.id.tv_number,!"0".equals(item.getCawdNum())?item.getCawdNum()+"CAWD":item.getUsdtNum()+"USDT")
                .setText(R.id.tv_time, TimeUtils.millis2String(item.getTransferTime()));
    }
}
